package com.example.weather.data;

import androidx.room.Dao;
import androidx.room.Insert;
import androidx.room.Query;

import java.util.List;

@Dao
public interface CityDao {
    @Insert
    void insetCity(City city);
    @Query("delete from city")
    void deleteAll();
    @Query("delete from city where name =:name")
    void deleteByName(String name);
    @Query("select * from city")
    List<City> findAll();
    @Query("select * from city where name= :name")
    City findByName(String name);
}
